Grouping results according to a geographical range instead of a single point.
aroundPrecision
) is used to group results that have more or less the same distance from a central point.
Algolia’s default precision is 10 meters.
However, a 10-meter difference might not be significant: intervals of 200 meters may make more sense.
By creating 200-meter intervals, you rank all records that fall within that interval the same.
They’re ranked higher than all records between 200 and 400 meters.
If you set aroundPrecision
to 200, you’ll have the following search results:
aroundPrecision
to 200, restaurant A and B will be ranked equally: the distances of 150 and 100 will be considered equal to 0 (and distances of 250 and 210 will be equal to 200, and so on).
Going further, since the results of A and B are tied under the Geo
criterion, the search engine will examine the other criteria in the ranking formula to further sort the results. Restaurant A will therefore be ranked higher in the result due to its higher rating.